home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++,rec.games.programmer,alt.msdos.programmer,comp.programming
- Path: empros.com!lmichael
- From: lmichael@empros.com (Lars Michael)
- Subject: Re: Young programmers read me.
- Sender: news@empros.com (ems-news)
- Message-ID: <Dq0wJ4.8oA@empros.com>
- Date: Wed, 17 Apr 1996 20:21:03 GMT
- References: <4l1dn6$j3@belle.bork.com>
- Nntp-Posting-Host: pern.empros.com
- Organization: Siemens-Empros Power Systems Control
- X-Newsreader: Tin 1.1 PL5
-
- Randy Scott (scottr@belle.bork.com) wrote:
- > : >or this:
- > : > if(something_happened)
- > : > { do_something_else(); }
- > :
- > : Extraneous braces cause pause.
- >
- > I would have to agree, use braces only when absolutely necessary.
-
-
- Hmm, I recommend exactly the opposite:
-
- _Always_ use braces.
-
-
- Reasons?
-
- 1) No bad surprises when using Macros.
-
- 2) No confusion about which if an else belongs to.
-
- 3) Indentation is more regular.
-
-
- Regards,
- Larry
- --
- Lars "Larry" Michael "Sanity is madness put to
- lmichael@empros.com good use."
- lars@frankendata.de - George Santayana
- da291@fim.uni-erlangen.de
-